my $manifestTemplate = "AndroidManifest.xml.template";
my $placeHolder = "__PUBLISH_MARKET__";
my @marketNames = ("google", "appChina", "hiapk", "WAPS", "gfan", "meizu");
#my @marketNames = ("google");
for my $market (@marketNames) {
  print "Prepare for $market\n";
  system("perl -p -e \"s/$placeHolder/$market/\" $manifestTemplate > AndroidManifest.xml");
  print "Building for $market\n";
  system("ant release < passwd.txt");
  print "Post job for $market\n";
  system("mv bin/airreport-release.apk bin/airreport-release-$market.apk");
}
